<extend name="Common/list-tree" />
<block name="batch">
    <div class="input-group">
        <span class="text-icon"> 批 量 </span>
        <select name="batch">
            <option value="sort">排序</option>
        </select>
    </div>
</block>

<block name="list">
    <tr>
        <th width="50" class="tc">排序</th>
        <th width="200">名称</th>
        <th>规则</th>
        <th width="50" class="tc">类型</th>
        <th width="50" class="tc">图标</th>
        <th width="50" class="tc">状态</th>
        <th width="300">操作</th>
    </tr>
    <foreach name="list" item="v">
    <tr id="{$v.id}" pId="{$v.pid}">
        <td class="tc"><input class="tc" type="text" name="sort[{$v.id}]" value="{$v.sort}" size="1"></td>
        <td>{$v.title}</td>
        <td>{$v.name}</td>
        <td class="tc">{:int_str($v['type'],'1:节点,2:菜单,3:分组')}</td>
        <td class="tc"><notempty name="v['icon']"><i class="icon-{$v['icon']} ft28"></i></notempty></td>
        <td class="tc">{:int_str($v['status'],'0:false,1:true')}</td>
        <td>
            <neq name="v.type" value="1">
                <a class="AjaxHtml btn btn-green mrt10" data-url="{:U('add?pid='.$v['id'])}" href="javascript:;">添加子菜单</a>
            </neq>
            <a class="AjaxHtml btn btn-blue mrt10" data-url="{:U('edit?id='.$v['id'])}" href="javascript:;">编辑菜单</a>
            <a class="AjaxConfirm btn btn-red mrt10" data-url="{:U('del?id='.$v['id'])}" href="javascript:;">删除菜单</a>
        </td>
    </tr>
    </foreach>
</block>